package mylibrary.excel;

import java.io.FileInputStream;
import java.io.FileNotFoundException;
import java.io.IOException;

import org.apache.poi.hssf.usermodel.HSSFCell;
import org.apache.poi.hssf.usermodel.HSSFRow;
import org.apache.poi.hssf.usermodel.HSSFSheet;
import org.apache.poi.hssf.usermodel.HSSFWorkbook;
import org.apache.poi.poifs.filesystem.POIFSFileSystem;

public class Test {

	public static void main(String[] args) throws Exception {
		
		POIFSFileSystem fs = new POIFSFileSystem(new FileInputStream("c:\\test.xls"));   
		HSSFWorkbook wb = new HSSFWorkbook(fs);   
		
//		HSSFSheet sheet = wb.getSheetAt(0);
//		
//		HSSFRow row = sheet.getRow(0); 
//		
//		HSSFCell cell = row.getCell(0);
//		
//		System.out.println(cell.getCellType());
		//System.out.println(cell.getStringCellValue());
		
		//System.out.println(cell.toString());
		
		HSSFSheet sheet = wb.getSheet("");
		
		HSSFRow row = sheet.getRow(13); 
		
//		HSSFCell cell = row.getCell(6);
//		System.out.println(cell.getCellFormula());
//		System.out.println(cell.getNumericCellValue());

		
//		HSSFCell cell2 = row.getCell(1);
//		System.out.println(cell2.getCellFormula());
//		System.out.println(cell2.getCellFormula());
//		System.out.println(cell2.toString());
		
	}
}
